import { createRouter, createWebHistory } from 'vue-router'
import login from '../views/LoginPage.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',//根目录
      name: 'login',
      component: login,
    },{
      path: '/register',
      name: 'register',
      component: () => import('@/views/RegisterPage.vue')
    },{
      path: '/index',
      name: 'index',
      component: () => import('@/views/IndexView.vue')
    }
    ,{
      path: '/forget',
      name: 'forget',
      component: () => import('@/views/ForgetPage.vue')
    }
  ]
})

export default router
